Skip to content

Conversation

@yashwanthatla
Copy link
Owner

@yashwanthatla yashwanthatla commented Jun 21, 2025

PR Summary

Add Sentinel class for unique typing sentinel objects

Overview

This PR adds a new Sentinel class to create unique sentinel objects for typing purposes, with special handling for Python versions before 3.11. The class is exposed as a public API and includes comprehensive test coverage.

Change Types

Type Description
Feature New Sentinel class for typing purposes
Test Test cases for the new Sentinel class

Affected Modules

Module / File Change Description
typing_extensions.py Added new Sentinel class and exposed it in __all__
test_typing_extensions.py Added import and test cases for Sentinel class

Notes for Reviewers

  • Special handling is implemented for Python versions before 3.11
  • Tests cover representation, type expression unions, non-callable behavior, and non-picklable behavior

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants